

package cn.edu.hbwe.book.dao;

import java.sql.ResultSet;

import java.sql.SQLException;
import java.util.ArrayList;
import java.util.List;

import org.apache.commons.dbutils.QueryRunner;
import org.apache.commons.dbutils.ResultSetHandler;

import cn.edu.hbwe.book.entity.Order;
import cn.edu.hbwe.book.entity.User;
import cn.edu.hbwe.book.utils.C3p0Util;
import cn.edu.hbwe.book.utils.DBCPUtil;


public interface OrderDao {
	
	/**
	 *  生成订单
	 * @param order
	 * @throws SQLException
	 */
	public static void addProduct(Order order) throws SQLException {}
	/**
	 *  查找所有订单
	 * @return
	 * @throws SQLException
	 */
	public List<Order> findAllOrder() throws SQLException;
	public List<Order> findOrderByManyCondition(String id, String receiverName) throws SQLException;
	//根据登陆的用户查找用户的订单
	public List<Order> findOrderByUser(User user) throws Exception;
	//根据订单的id查找订单的详细信息
	public Order findOrderById(String id) throws SQLException;
	//根据id删除订单
	public void delOrderById(String id) throws SQLException;
	public void updateOrderState(String id) throws SQLException;
	
}

